
if exists(select name from sysobjects where name = 'sp_SinhVienResetMK')
	drop proc sp_SinhVienResetMK
go
/*
	Created by: Phuoc NH
	Created on: 13/05/2013 (dd/mm/yyyy)
	Description: 
	--

	File:$sql-scripts/Proc.sp_SinhVienResetMK.sql
*/

create proc sp_SinhVienResetMK
@MaSinhVien varchar(50)
as
begin
	update SinhVien set MatKhau=CONVERT(VARCHAR(32),HashBytes('MD5',REPLACE(convert(varchar(10),NgaySinh,103),'/','')),2), TrangThaiupdate=2 where MaSinhVien=@MaSinhVien
end

